package day04;
//此类是用于验证if单路分支的测试demo
public class Test01 {
    public static void main(String[] args) {
        //if判断单路分支语法格式
        /*
        if(boolean)
         */

        //需求:购物满500打8折  -------条件给：购买满500 才能打8折
        double price = 600;
        if (price >= 500) {
            price = price * 0.8;
            System.out.println("消费金额为:" + price + "元");          //输出 消费金额为:480.0元
        }

    }
}
